package com.design.oop.bean;

import java.util.Comparator;

public class WheatBeerRateComparator implements Comparator<WheatBeerKind> {
	@Override
	public int compare(WheatBeerKind o1, WheatBeerKind o2) {
		if (o1 == null || o2 == null) {
			return 0;
		}

		return o2.getRate().compareTo(o1.getRate());
	}
}
